home *** CD-ROM | disk | FTP | other *** search
- Path: mail2news.demon.co.uk!genesis.demon.co.uk
- From: Lawrence Kirby <fred@genesis.demon.co.uk>
- Newsgroups: comp.lang.c++,comp.lang.c
- Subject: Re: HELP: no mapping at the fault address
- Date: Sat, 06 Apr 96 22:27:41 GMT
- Organization: none
- Message-ID: <828829661snz@genesis.demon.co.uk>
- References: <opybocswab.fsf@sweetbay.will.uiuc.edu> <4k3qn8$1gk6@msunews.cl.msu.edu>
- Reply-To: fred@genesis.demon.co.uk
- X-NNTP-Posting-Host: genesis.demon.co.uk
- X-Newsreader: Demon Internet Simple News v1.27
- X-Mail2News-Path: genesis.demon.co.uk
-
- In article <4k3qn8$1gk6@msunews.cl.msu.edu>
- jliu@perm.fw.msu.edu "Jianguo Liu" writes:
-
- >Hello, everyone:
- >
- >I had an error when running a program in SPARCcompiler C++
- >4.0.1 (Solaris 2.4). The error was deteced using dbx. The
- >message was
- >
- >**********************************
- >
- >signal SEGV (no mapping at the fault address) in t-splay at
- >0xef6bc470.
- >
- >The current line is
- >
- >new_ptr=(strucut tree *) malloc(sizeof(struct tree));
-
- Did you include stdlib.h? You must ensure that all functions that don't
- return int or are variadic are declared (it is best that all functions are
- declared). If that isn't the problem your program probably corrupted the
- heap earlier by some illegal pointer operation such as writing outside
- array bounds, using undefined pointers, or passing illegal pointers to free
- (i.e. pointers to objects not allocated from the heap or already freed).
-
- You should also be a little more clear whether you are using C or C++.
-
- --
- -----------------------------------------
- Lawrence Kirby | fred@genesis.demon.co.uk
- Wilts, England | 70734.126@compuserve.com
- -----------------------------------------
-